Page({
  data: {},
  onLoad({ id }) {
    // 获取房屋详情
    this.houseId = id
    this.getDeatil()

  },
  /**
   * 获取房屋详情
   */
  async getDeatil() {
    const { data } = await wx.http.get(`/room/${this.houseId}`)
    this.setData({
      ...data
    })
  },
  editHouse() {
    // 跳转添加房屋页面=》实现修改
    wx.navigateTo({
      url: `/house_pkg/pages/form/index?id=${this.houseId}`,
    })
  },
})
